<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <title>论坛</title>

    <!-- Bootstrap -->
    <link href="/Finder/Public/Css/bootstrap.min.css" rel="stylesheet">
    <link rel="stylesheet" href="/Finder/Public/Css/header.css"/>
    <link rel="stylesheet" href="/Finder/Public/Css/blogIndex.css"/>
    <style>
        #blog {
            border-bottom: 2px solid #e67e22;
            margin-bottom: -2px;
        }
    </style>
    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
    <script src="http://cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js"></script>
    <script src="http://cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
</head>
<body>
    <header role="navigation" class="header">
    <div class="container">
        <div class="row">
            <div class="col-md-2 col-sm-2 .navbar-left">
                <a href="<?php echo U('Home/Index/index');?>" class="logo">
                    <img src="/Finder/Public/Img/logo-finder.png" alt="logo" class="logo1">
                </a>
            </div>
            <div class="col-md-8 col-sm-8 text-center">
                <div class="collapse navbar-collapse" id="main-menu">
                    <ul class="menu">
                        <li id="index" role="presentation"><a href="<?php echo U('Home/Index/index');?>"><span>首页</span></a></li>
                        <li id="publish" role="presentation"><a href="<?php echo U('Home/Blog/publish');?>"><span>发布</span></a></li>
                        <li id="blog" role="presentation"><a href="<?php echo U('Home/Blog/index');?>"><span>论坛</span></a></li>
                    </ul>
                </div>
            </div>
            <div class="col-md-2 col-sm-2 text-right">
                <div class="link-group">
                    <a href="<?php echo ($user_manage["url1"]); ?>"><?php echo ($user_manage["value1"]); ?></a>
                    <span>|</span>
                    <a href="<?php echo ($user_manage["url2"]); ?>"><?php echo ($user_manage["value2"]); ?></a>
                </div>
            </div>
        </div>
    </div>
</header>
    <div class="container search">
        <div class="row">
            <div class="col-md-3"></div>
            <div class="col-md-6">
                <form action="" class="navbar-search form-inline navbar-form" id="search_form" method="post">
                    <input type="search" class="form-control search-query" name="search-content" id="search-text"/>
                    <button class="btn btn-default" type="submit" name="search" id="search-btn">搜索</button>
                </form>
            </div>
            <div class="col-md-3"></div>
        </div>
        <div class="row">
            <!--//content-->
            <div class="blog-area col-md-offset-2 col-md-8">
                <div class="blog-content" role="tabpanel">
                    <!--//论坛导航-->
                    <ul class="nav nav-tabs" role="tablist">
                        <li role="presentation" >
                            <a href="#home" aria-controls="home" role="tab"
                                                onclick="show(2)"          data-toggle="tab">寻找</a>
                        </li>
                        <li role="presentation" >
                            <a href="#found" aria-controls="profile" role="tab"
                                                data-toggle="tab" onclick="show(1)">招领</a>
                        </li>
                        <li role="presentation" >
                            <a href="#messages" aria-controls="messages" role="tab" data-toggle="tab" onclick="show(3)">正能量</a>
                        </li>
                        <li role="presentation" class="active">
                            <a href="#settings" aria-controls="settings" role="tab"
                                               onclick="show(4)"           data-toggle="tab">零下</a>
                        </li>
                    </ul>
                    <div class="tab-content">
                        <div role="tabpanel" class="tab-pane" id="home"></div>
                        <div role="tabpanel" class="tab-pane" id="found"></div>
                        <div role="tabpanel" class="tab-pane" id="messages"></div>
                        <div role="tabpanel" class="tab-pane active" id="settings">
                            
    <div class="posts-content">
        <div class="postshead" style="width: 100%;">
            <h4><?php echo ($posts["blog"]["blog_title"]); ?></h4>
        </div>
        <div class="postsbody">
            <div class="blogcontent">
                <p><?php echo ($posts["blog"]["blog_content"]); ?></p>
            </div>
            <hr/>
            <div class="goods-content">
                <span>相关图片：</span><br /><img src="/finder<?php echo ($posts["blog"]["energy_blog_picture"]); ?>" alt="picture"/>
            </div>
            <div class="user-info">
                <hr style="margin-bottom: 5px"/>
                <h4 class="text-center">为他们喝彩！</h4>

            </div>

            <div class="posts-info">
                <p class="text-right">
                    <a href=""><?php echo ($posts["user"]["user_name"]); ?></a>
                    <span>|1楼 <?php echo (date("Y-m-d  H:i:s",$posts["blog"]["blog_date"])); ?></span>
                </p>
            </div>
        </div>
        <!--回复列表-->
        <div class="replies-list">
            <ul class="reply-list">
                <?php if(is_array($posts["replies"])): foreach($posts["replies"] as $key=>$rep): ?><li class="clearfix">
                        <div class="li-block" style="border-radius: 0px">
                            <!--//这里的U方法传参的时候数组要写原生形式，不能写成array.xx-->
                            <p><?php echo ($rep["reply_content"]); ?></p>
                            <div class="reply-info">
                                <p class="text-right">
                                    <a href=""><?php echo ($rep["user_name"]); ?></a>
                                    <span>|<?php echo ++$floor_count;?>楼 <?php echo (date("Y-m-d  H:i:s",$rep["reply_time"])); ?></span>
                                </p>
                            </div>
                        </div>
                    </li><?php endforeach; endif; ?>
            </ul>
            <div style="clear:both;height:0;font-size: 1px;line-height: 0px;"></div>
        </div>
        <!--回复域-->
        <div class="reply-area">
            <form class="reply" id="reply-form" action="<?php echo U('Blog/reply',array('area_id'=>4));?>" method="post">
                <input type="hidden" name="blog_id" value="<?php echo ($posts["blog"]["blog_id"]); ?>"/>
                <input name="reply_type" value="0" type="hidden"/>
                <textarea name="reply_content" id="reply_area-text" rows="6"></textarea>
                <button class="btn btn-default" id="btn-reply" type="submit">回复</button>
            </form>
        </div>
    </div>

                            
    <div class="blog-page">
        <?php echo ($posts["page"]); ?>
    </div>

                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <script src="/Finder/Public/Js/jquery.min.js"></script>
    <script src="/Finder/Public/Js/bootstrap.min.js"></script>
    <script src="/Finder/Public/Js/reply.js"></script>
</body>
</html>